package com.wx.sys.web;

import com.alibaba.fastjson.JSON;
import com.wx.sys.mapper.SysUserMapper;
import com.wx.sys.model.SysUser;
import com.wx.sys.service.SysUserFeignApi;
import com.wx.util.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;

/**
 * Created by king-pc on 2018/12/3.
 */
@RestController
public class SysUserFeignClient implements SysUserFeignApi {

    @Autowired
    private SysUserMapper sysUserMapper;

    @Override
    public SysUser getUserInfo(@RequestParam("account") String account){
        SysUser user = sysUserMapper.selectByAccount(account);
        return user;
    }

}
